package com.woniuxy.microretailserver.service;

import com.github.pagehelper.PageInfo;
import com.woniuxy.microretailserver.bean.*;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * @author chenhu
 * 订单商品业务层接口
 */
public interface IGoodsOrderService {

    /**
     * 新增购买订单信息
     *
     * @param goodsOrderBean
     * @param orderGoodsBean
     * @return
     */
    int saveGoodsOrder(GoodsOrderBean goodsOrderBean, List<OrderGoodsBean> orderGoodsBean, GoodsPayBean goodsPayBean);

    /**
     * 分页查询商品购买订单
     * @param request
     * @param goodsOrderBean
     * @return
     */
    PageInfo<GoodsOrderBean> findAllGoodsOrder(PageRequest request,GoodsOrderBean goodsOrderBean);

    /**
     * 根据订单号查询详细信息
     * @param orderNo
     * @return
     */
    HashMap<String,Object> findAll(String orderNo);

    /**
     * 分页查询订单及支付信息
     * @param request
     * @param goodsOrderBean
     * @return
     */
    PageInfo<GoodsOrderBean> findAllGoodsOrderPay(PageRequest request,GoodsOrderBean goodsOrderBean);

    /**
     * 导出订单数据
     * @return
     */
    List<GoodsOrderExportBean> findByAllOrder();

    /**
     * 导出订单与账户表数据
     * @return
     */
    List<GoodsOrderPayExportBean> findByAllGoodsPay();
}
